<!DOCTYPE html>
<html lang="en">
   <head>
      <meta charset="UTF-8">
      <title>商品价格</title>
      <style>
          * {
              text-align: center;
          }
          table, th, td {
              border: 2px solid #000;
              border-collapse: collapse;
          }
          table {
              width: 600px;
              height: 100px;
              margin: 0 auto;
          }
      </style>
   </head>
   <body>
      <h1>订单确认</h1>
      <script>
         let goodsName = prompt('请输入商品名称')
         let goodsPrice = prompt('请输入商品价格')
         let goodsNum = prompt('请输入商品数量')
         let goodsTotal = goodsPrice * goodsNum
         let goodsAddress = prompt('请输入收货地址')
         document.write(`
         <table>
         <tr>
            <th>商品名称</th>
            <th>商品价格</th>
            <th>商品数量</th>
            <th>总价</th>
            <th>收货地址</th>
         </tr>
         <tr>
            <td>${goodsName}</td>
            <td>${goodsPrice}元</td>
            <td>${goodsNum}</td>
            <td>${goodsTotal}元</td>
            <td>${goodsAddress}</td>
         </tr>
      </table>
         `)
      </script>
   </body>
</html>